<!--

生成最基本的Restful模板页面

顶部有按（门店、时间段*）查询 添加按钮

包含一个 ag-grid 列表，默认表头只有一行，每列都可查询，默认每条最后有打开、删除按钮

有新增、修改弹出层
-->

<div class="view-header">
    <div class="view-header-left">


        <div class="view-header-item color-open" title="[[TITLE_HEADER_ADD]]"
             ng-click="add_open = !add_open">
            <i class="fa fa-plus"></i>
        </div>

        <div class="view-header-item color-close above-cover"
             title="[[TITLE_HEADER_ADD_CLOSE]]" ng-click="add_open = !add_open"
             ng-show="add_open">
            <i class="fa fa-close"></i>
        </div>

        <div class="view-header-item color-check above-cover"
             title="确认添加"
             ng-click='form_add.$valid?submit_add():{};'
             title="添加提交{{form_add.$invalid?'请完成表单后再提交!':''}}"
             ng-show="add_open">

            <i class="fa fa-check" ng-show="form_add.$valid"></i>
            <i class="fa fa-ban" ng-show="form_add.$invalid"></i>

        </div>

        <!-- edit-->
        <div class="view-header-item color-close above-cover"
             title="[[TITLE_HEADER_EDIT_CLOSE]]"
             ng-click="edit_open = !edit_open" ng-show="edit_open">
            <i class="fa fa-close"></i>
        </div>

        <div class="view-header-item color-check above-cover"
             title="确认修改"
             ng-click='form_edit.$valid?submit_edit():{};'
             title="修改提交{{form_add.$invalid?'请完成表单后再提交!':''}}"
             ng-show="edit_open">

            <i class="fa fa-check" ng-show="form_edit.$valid"></i>
            <i class="fa fa-ban" ng-show="form_edit.$invalid"></i>
        </div>

        <!-- 选择题目 -->
        <div class="view-header-item color-close above-cover no-widen"
             title="选择题目--关闭" ng-click="question_open = false"
             ng-show="question_open">
            <i class="fa fa-close"></i>
        </div>

    </div>

</div>
<div class="view-content ">
    <div ag-grid="grid" class="ag-blue ag-custom ag-custom-center" style="height :100%"></div>
</div>

<div class="data-overlay" ng-show="add_open">
    <div class="overlay-container">
        <div class="overlay-header">temp_add</div>
        <div ng-form name="form_add" novalidate="novalidate">
            <div class="new-block">

                <div class="new-item">
                    <span>标题</span>
                    <input ng-model="record_add.name"/>
                </div>
                <div ng-repeat="item in record_add.question">
                    <div class="new-item">
                        <span>{{$index+1}}</span>
                        <span>{{item.content}}</span>
                    </div>
                </div>
                <div class="new-item">
                    <span class="overlay-name">选择题目</span>
                    <input type="text" ng-click="choose_question()" readonly="" placeholder="点击选择题目"/>
                    <div class="overlay-item-choose">
                        <i class="fa fa-chevron-right" style="padding-right:5px;"></i>
                    </div>
                </div>


            </div>

        </div>
    </div>
</div>

<div class="data-overlay" ng-show="edit_open">
    <div class="overlay-container">
        <div class="overlay-header">temp_edit</div>
        <div ng-form name="form_edit" novalidate="novalidate">
            <div class="new-block">

            </div>

        </div>
    </div>
</div>

<div class="data-overlay" ng-show="question_open">
    <div class="overlay-container no-scroll">
        <div class="overlay-header">选择题目</div>
    </div>
    <div class="overlay-content-ag">
        <div ag-grid="question_kpi" class="ag-fresh ag-custom-center" style="height :100%"></div>
    </div>
</div>